package com.yuke.cloud.service.omc.entity;

import com.yuke.cloud.service.api.pmc.dto.ProdAttributeDto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.persistence.*;
import java.util.List;

@ApiModel(value = "com.yuke.cloud.service.omc.entity.OdsOrderGoods")
@Table(name = "ods_order_goods")
@Data
public class OdsOrderGoods {
    /**
     * 主键，自增
     */
    @Id
    @Column(name = "order_goods_id")
    @ApiModelProperty(value = "orderGoodsId主键，自增")
    private Long orderGoodsId;

    @Transient
    private String imagesAddress;
    @Transient
    private String specName;
    @Transient
    private Integer totalmoney;
    @Transient
    private Long categoryId;
    @Transient
    private String specCode;
    @Transient
    private Integer price;
    @Transient
    private Long giftId;
    @Transient
    private Boolean hasTying;
    @Transient
    private Integer hasRebate;
    @Transient
    private String bigPic;
    /**
     * 属性名称
     */
    @Transient
    @ApiModelProperty(value="attributeName属性名称")
    private String attributeName;

    /**
     * 对应的属性值，如果是重量，值为整型，单位为克。对于复选值，每个值中间用【;】号隔开
     */
    @Transient
    @ApiModelProperty(value="attributeValue对应的属性值，如果是重量，值为整型，单位为克。对于复选值，每个值中间用【;】号隔开")
    private String attributeValue;

    private List<ProdAttributeDto> prodAttributeDto;

    /**
     * 订单ID
     */
    @Column(name = "order_id")
    @ApiModelProperty(value = "orderId订单ID")
    private Long orderId;

    /**
     * 商品规格ID
     */
    @Column(name = "spec_id")
    @ApiModelProperty(value = "specId商品规格ID")
    private Long specId;

    /**
     * 商品ID
     */
    @Column(name = "product_id")
    @ApiModelProperty(value = "productId商品ID")
    private Long productId;

    /**
     * 商品销售价格，单位为分
     */
    @Column(name = "goods_price")
    @ApiModelProperty(value = "goodsPrice商品销售价格，单位为分")
    private Integer goodsPrice;

    /**
     * 商品实付金额，单位为分
     */
    @Column(name = "pay_price")
    @ApiModelProperty(value = "payPrice商品实付金额，单位为分")
    private Integer payPrice;

    /**
     * 商品数量
     */
    @Column(name = "goods_num")
    @ApiModelProperty(value = "goodsNum商品数量")
    private Integer goodsNum;

    /**
     * 商品重量，单位为克
     */
    @Column(name = "goods_weight")
    @ApiModelProperty(value = "goodsWeight商品重量，单位为克")
    private Integer goodsWeight;

    /**
     * 商品属性，json串
     */
    @Column(name = "goods_attribute")
    @ApiModelProperty(value = "goodsAttribute商品属性，json串")
    private String goodsAttribute;

    /**
     * 是否已发货，0：未发货，1：已发货，2：已退货。
     */
    @Column(name = "goods_status")
    @ApiModelProperty(value = "goodsStatus是否已发货，0：未发货，1：已发货，2：已退货。")
    private Byte goodsStatus;

    /**
     * 物流单ID，与订单配送信息ods_order_delivery表关联
     */
    @Column(name = "order_delivery_id")
    @ApiModelProperty(value = "orderDeliveryId物流单ID，与订单配送信息ods_order_delivery表关联")
    private Long orderDeliveryId;

    /**
     * 发货仓库ID
     */
    @Column(name = "warehouse_id")
    @ApiModelProperty(value = "warehouseId发货仓库ID")
    private Long warehouseId;

    /**
     * 发货仓库ID
     */
    @Column(name = "storage_id")
    @ApiModelProperty(value = "storageId发货仓库ID")
    private Long storageId;

}